<?php
	$arrStatusLabel = array('active' => 'Active', 'inactive' => 'Inactive');
	$configObj 		= new Zendvn_Controller_Config(array('module'	=>$this->arrParam['module'],
														'fileConfig'=>'user.ini'));
	$itemConfig = $configObj->getConfig('config');
	if(!empty($this->Item)){
		$id			= $this->Item['id'];
		$first_name = Zendvn_Filter_Filter::filterContent($this->Item['first_name'], 'filter');
		$last_name 	= Zendvn_Filter_Filter::filterContent($this->Item['last_name'], 'filter');
		$email		= $this->Item['email'];
		
		$avatar		= $this->Item['avatar'];
		
		if(file_exists($itemConfig['thumbDir3'] . '/' . $avatar) && !empty($avatar)){
			$avatar_url	= $itemConfig['thumbUrl3'] . '/' . $avatar;
		}else{
			$avatar_url = FILE_URL . '/sys-images/no-avatar.jpg';
		}
		$avatar	= $this->cmsImage('avatar', $avatar_url, array('class' => 'img-polaroid', 'width' => '250'));
		
		
		$birthday	= $this->Item['birthday'];
		$sign		= Zendvn_Filter_Filter::filterContent($this->Item['sign']);
		$created	= $this->Item['created'];
		$created_ip	= $this->Item['created_ip'];
		
		$status		= $this->Item['status'];
		if($status == 'active'){
			$clssStatus = 'label label-success arrowed-in';
		}else{
			$clssStatus = 'label arrowed-in';
		}
		$status = '<span id="tbl-status-btn" data-status="' . $status . '" class="' . $clssStatus . '">' . $arrStatusLabel[$status] . '</span>';
		
		$group		= $this->Item['group_name'];
		
		$arrRow = array(
					array('label'=>$this->translate('ID'), 'info'=>$id),
					array('label'=>$this->translate('First Name'), 'info'=>$first_name),
					array('label'=>$this->translate('Last Name'), 'info'=>$last_name),
					array('label'=>$this->translate('Email'), 'info'=>$email),
					array('label'=>$this->translate('Avatar'), 'info'=>$avatar),
					array('label'=>$this->translate('Birthday'), 'info'=>$birthday),
					array('label'=>$this->translate('Created'), 'info'=>$created),
					array('label'=>$this->translate('Created IP'), 'info'=>$created_ip),
					array('label'=>$this->translate('Sign'), 'info'=>$sign),
					array('label'=>$this->translate('Status'), 'info'=>$status),
					array('label'=>$this->translate('Group'), 'info'=>$group)
				
				);
	}
?>
<?php echo $this->partial($this->includeDir . '/submenu.php', array('main_title' => 'Users Manager', 'sub_title' => 'User Information'));?>

<div class="row-fluid">
	<div class="span12">
		<form class="form-horizontal" role="form">
	  		<?php echo $this->partialLoop('row-info.php',$arrRow);?>
    	</form>
	</div>
</div>